/*
 * networkcontext.h
 *
 *  Created on: Sep 20, 2011
 *      Author: anonovermind <anonovermind@gmail.com>
 */

#ifndef NETWORKCONTEXT_H_
#define NETWORKCONTEXT_H_

#include <ostream>
#include <istream>
#include <memory>

namespace Wishmaster2
{
namespace Network
{

class NetworkContext
{
public:
	NetworkContext()
	{
	}

	virtual ~NetworkContext()
	{
	}

	virtual void serialize(std::ostream& stream) = 0;
	virtual void deserialize(std::istream& stream) = 0;

	virtual void setParameters(const std::string& str) = 0;
};

typedef std::shared_ptr<NetworkContext> NetworkContextPtr;
typedef std::weak_ptr<NetworkContext> NetworkContextWeakPtr;

} /* namespace Network */
} /* namespace Wishmaster2 */
#endif /* NETWORKCONTEXT_H_ */

